package accountmanager.accounts;

public abstract class Account{
	
	private double balance; 
	
	//public static String toString;
	public abstract String getName();
	@Override public String toString(){
		return getName();
	}
	
	public double getBalance(){
		return balance;
	}
	
	public double deposit(Double amount){
		balance += amount;
		return balance;
	}
	
	public double withdraw(Double amount){
		balance -= amount;
		return balance;
	}
}
